﻿@using Gfw.Infrastructure.Stock.Enums
@model Gfw.Infrastructure.Stock.Enums.MarketRunningStateEnum
@{
    ViewBag.Title = "游戏状态管理";
    Layout = "~/Areas/Stock/Views/Shared/_StockLayoutContent.cshtml";
}
@using (Html.BeginForm())
{
    <ul>
        <li>GP游戏当前状态： </li>
        <li>
            <h2>
                @if (Model == Gfw.Infrastructure.Stock.Enums.MarketRunningStateEnum.Off)
                {
                    <span>关闭</span>
                }
                else if (Model == Gfw.Infrastructure.Stock.Enums.MarketRunningStateEnum.Original)
                {
                    <span>申购</span>
                }
                  else if (Model == Gfw.Infrastructure.Stock.Enums.MarketRunningStateEnum.Tensile)
                {
                    <span>拉伸</span>
                }
                else if (Model == Gfw.Infrastructure.Stock.Enums.MarketRunningStateEnum.Normal)
                {
                    <span>运行</span>
                }
            </h2>
        </li>
        <li>更改状态：</li>
        <li>
            @Html.DropDownList("newstate", new List<SelectListItem>()
                                         {
                                             new SelectListItem() {Value = ((int) MarketRunningStateEnum.Original).ToString(), Text = "申购"},
                                                                                          new SelectListItem() {Value = ((int) MarketRunningStateEnum.Tensile).ToString(), Text = "拉伸"},
                                             new SelectListItem() {Value = ((int) MarketRunningStateEnum.Normal).ToString(), Text = "正常"},
                                             new SelectListItem() {Value = ((int) MarketRunningStateEnum.Off).ToString(), Text = "关闭"},
                                         })
            @Html.ValidationSummary(true)
        </li>
    </ul>
    <div class="button">
        @Html.ActionLink("返回", "Index")
        <input type="submit" value="修改" />
    </div>
     
}
